import request from '@/utils/request'

// 查询广告投放记录列表
export function listAdvertisementLog(query) {
  return request({
    url: '/seller/advertisementLog/list',
    method: 'get',
    params: query
  })
}

// 查询广告投放记录详细
export function getAdvertisementLog(id) {
  return request({
    url: '/seller/advertisementLog/' + id,
    method: 'get'
  })
}

// 新增广告投放记录
export function addAdvertisementLog(data) {
  return request({
    url: '/seller/advertisementLog',
    method: 'post',
    data: data
  })
}

// 修改广告投放记录
export function updateAdvertisementLog(data) {
  return request({
    url: '/seller/advertisementLog',
    method: 'put',
    data: data
  })
}

// 删除广告投放记录
export function delAdvertisementLog(id) {
  return request({
    url: '/seller/advertisementLog/' + id,
    method: 'delete'
  })
}

// 获取运营的erp用户列表
export function getUserList() {
  return request({
    url: '/seller/advertisementLog/getUserList',
    method: 'get'
  })
}

// 根据ERP用户id获取店铺列表
export function getStoreListByUserId(id) {
  return request({
    url: '/seller/advertisementLog/getStoreListByUserId/' + id,
    method: 'get'
  })
}